package com.lmk.feign;


import com.lmk.domain.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

// 指定需要调用的服务的应用名称
@FeignClient(name="user-service",fallbackFactory = UserServiceFallbackFactory.class)
@RequestMapping("/user")
public interface UserService {

    @GetMapping("/getUserById/{id}")
    User getUserById(@PathVariable("id") Long id);
}